package com.mao.answersclouddata.controller;

import com.mao.answersclouscommon.common.JsonResponseMsg;
import com.mao.answersclouddata.dao.ClickLinkMapper;
import com.mao.answersclouscommon.entity.ClickLink;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.Map;

@RestController
public class TestController {

    @Autowired
    private ClickLinkMapper userService;



    /**
     * 登出
     */
    @RequestMapping(value = "/logout")
    public JsonResponseMsg logout() {
        JsonResponseMsg result = new JsonResponseMsg();
        ClickLink clickLink = userService.selectByPrimaryKey((long) 417);
        Map<String,Object> map = new HashMap<>();
        map.put("aa",clickLink.getCooperativePartnerId());
        return result.fill(JsonResponseMsg.CODE_SUCCESS,"退出登录成功",map);
    }

}
